﻿
<!--
/**************************************************
* @ orderrecsigngoodsnonflat.jsp
*
* Copyright   2006 Hitrust Technology Inc.
* Developed by SDC, Hitrust.
* All Rights Reserved.
*
* Modify History:
*  v1.00, 2008/09/25, Tuthmos
*  1) first release
/**************************************************
-->
<%@ page contentType="text/html; charset=UTF-8" %>
<%@ include file="../../../common.jsp" %>
<%@ taglib uri="/page.util.gs.hitrust.com/taglibs/page" prefix="page"%>
<%@ page import="com.hitrust.gs.bean.GSOrderBean" %>
<html>
<head>
<title>订单查询明细浏览</title>
<META http-equiv=Content-Type content="text/html; charset=UTF-8">
<!--<LINK href="<%=root%>/css/css.css" type=text/css rel=stylesheet>-->
<link href="css/caigouxitong.css" rel="stylesheet" type="text/css">
<SCRIPT language="JavaScript" src="<%=root%>/js/common.js"></SCRIPT>
<SCRIPT language="JavaScript" src="<%=root%>/js/hi-check.js"></SCRIPT>
<SCRIPT language="JavaScript" src="<%=root%>/js/calendar.js"></SCRIPT>
<%
	String[] tStr = (String[])request.getAttribute("curorderdetail");
	GSOrderBean tBean = (GSOrderBean)request.getAttribute("orderbean");
%>
<%
if(message == null){
%>
<script language="JavaScript">
	var counter;
	function process(val){
  	    var iFields1 = new Array(6);
        iFields1[0] = 'devGoodsOrderId||送货单号||Y||1-10||#ABC';
        iFields1[1] = 'signer||签收人||Y||1-20||##';
        iFields1[2] = 'goodsUnitprice||价格||Y||1-15||#.';
        iFields1[3] = 'signCount||签收数量||Y||1-15||#.';        
        iFields1[4] = 'contactPerson||送货联系人||N||1-20||##';		
        iFields1[5] = 'contactPhone||联系电话||N||1-50||#0.';
        var ary = new Array(9);
		if(val == 'C'){
			if(HiScript.value('orderrecsigngoodsform',iFields1)==false) {
				return false;
			}					
//			if(isEmpty(signDate)){
//				alert("签收日期不能为空!");
//				return false;
//			}
			if(parseFloat(orderrecsigngoodsform.goodsUnitprice.value) > parseFloat(<%=tStr[17]%>)){
				alert("录入的产品价格不能大于原价格，请重新输入!");
				orderrecsigngoodsform.goodsUnitprice.focus();
				return false;
			}
			if(confirm("是否确定保存录入的收货确认信息?")){
				//orderrecsigngoodsform.action = "<%=response.encodeURL(root+"/A150405.do")%>";
				//orderrecsigngoodsform.submit();
				ary[0] = orderrecsigngoodsform.curOrderId.value;
				ary[1] = orderrecsigngoodsform.curOrderDetailId.value;
				ary[2] = orderrecsigngoodsform.devGoodsOrderId.value;
				ary[3] = orderrecsigngoodsform.signer.value;
				ary[4] = orderrecsigngoodsform.signCount.value;
				ary[5] = orderrecsigngoodsform.signDate.value;
				ary[6] = orderrecsigngoodsform.goodsUnitprice.value;
				ary[7] = orderrecsigngoodsform.contactPerson.value;
				ary[8] = orderrecsigngoodsform.contactPhone.value;
				window.returnValue = ary;
//				window.opener.location.href = window.opener.location.href;
				//window.opener.location.reload(); 
				window.close();
			}else{
				return false;
			}
		}
		
	}

</script>
</head>
<body text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<form name="orderrecsigngoodsform" mothed="post" >
<input type="hidden" name="curOrderId" value="<%=tBean.getGs_order_tempid() %>">
<input type="hidden" name="curOrderDetailId"  value="<%=tStr[0]%>">
<p><br></p>
<table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
	<tr>
		<td height="20">
			<table width="100%" border="0" cellspacing="0" cellpadding="1">
				<tr height="20">
					<td height="30" width="758" class="mtxt_black">订单信息
					</td>
				</tr>
			</table>
		</td>
	</tr>
	<tr>
		<td class="bg_line" height="2"></td>
	</tr>
</table>
<br>
	<center>
    <table width="98%" border="0" cellspacing="0" cellpadding="0" align="center">
    <tr>
    <td>
    <table class=bg_table id=tableId	cellspacing=1 cellpadding=0 width=100% align=center border=0>
    <tbody>
	<tr class="bg_row_odd" height="20">
		<td class="top" align="center" width='20%' id='aaa'><div align="center" class="txt_content">订单编号</div></td>
		<td  colspan=5 class="top" width="30%"><div class="txt_content">&nbsp;<%=tBean.getGs_order_tempid()%></div></td>
	</tr>
	<tr class="bg_row_odd" height="20">
	<td class="top" width="13%" align="center">订货单位</td>
	<td class="top" width="20%"><div class="txt_content" align="left">&nbsp;<%=GSBaseManager.getOrderDeptName(tBean.getGs_workcorp_id())%></div></td>
	<td class="top" width="13%" align="center">配送方式</td>
	<td class="top" width="20%"><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_deliver_mode()==null? "":GSBaseManager.getDeliverModeName(tBean.getGs_deliver_mode())%></div></td>
	<td class="top" width="13%" align="center">结算方式</td>
	<td class="top"><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_balance_mode() == null? "":GSBaseManager.getBalanceModeName(tBean.getGs_balance_mode())%></div></td>
	</tr>
	<tr class="bg_row_odd" height="20">
	<td class="top" width="13%" align="center">送货地址</td>
	<td class="top"><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_deliver_goods_addr()%></div></td>	
	<td class="top" width="13%" align="center">联系人</td>
	<td class="top"><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_order_contact_name()==null?"":tBean.getGs_order_contact_name()%></div></td>	
	<td class="top" width="13%" align="center">联系电话</td>
	<td class="top"><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_order_contact_phone()==null?"":tBean.getGs_order_contact_phone()%></div></td>	
	</tr>
	<tr class="bg_row_odd" height="50">
	<td class="top" width="13%" align="center">备注</td>
	<td class="top" colspan=5><div class="txt_content" align="left">&nbsp;<%=tBean.getGs_notes()%></div></td>	
	</tr>
	<tr class=bg_row_odd >
	<td class="top" width="13%" align="center">创建人</td>
	<td class="top"><div class="txt_content">&nbsp;<%=tBean.getGs_recorder_id()%></div></td>	
	<td class="top" width="13%" align="center">创建时间</td>
	<td class="top" colspan=3><div class="txt_content">&nbsp;<%=tBean.getGs_order_create_date()%></div></td>	
	</tr>
	</tbody>
	</table>
	<br>
            	<table class=bg_table id=tableId	cellspacing=1 cellpadding=2 width=100% align=center border=0>
                    <tbody> 
                    <tr class="bg_column" height=20> 
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">订单明细编号</div>
						</td>                    
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">集中编码</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">产品名称</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">产品类型</div>
						</td>						
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">规格</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">型号</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">品牌</div>
						</td>
                       <td class=top align=middle> 
                        <div align="center" class="txt_content">供应商</div>
						</td>						
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">订货数量</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">单位</div>
						</td>						
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">价格（元）</div>
						</td>						
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">总价（元）</div>
						</td>						
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">送货日期</div>
						</td>
                        <td class=top align=middle> 
                        <div align="center" class="txt_content">送货时间</div>
						</td>																																																																				
					</tr>
							<tr height=20 class="bg_row_odd">
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[0]%>
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[1]%>
									</div>
								</td>								
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<a href="<%=response.encodeURL(root+"/A150103.do")%>?&concentricityId=<%=tStr[1]%>" target="_blank"><%=tStr[2]%></a>
									</div>
								</td>
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[18]%>
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[3]%>
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[4]%>
									</div>
								</td>						
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[5]%>
									</div>
								</td>								
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%
										String temp = "";
										if(tStr[15].equals("0") && tStr[16].equals("0")){
										    temp = "(采购网配送)";
										}
									%>
									<a href="A400108.do?providerId=<%=tStr[14]%>" target="_blank"><%=tStr[6]%></a><%=temp%>
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[7]%>
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[8]%>
									</div>
								</td>									
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[17]%>元
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[10]%>元
									</div>
								</td>	
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[11]%>
									</div>
								</td>																									
								<td class=top align=middle> 
									<div align="center" class="txt_content">
									<%=tStr[12]%>
									</div>
								</td>																			
							</tr> 				
						</tbody>
					</table>	
				<br>	
				<table class="bg_table" id="tableId" cellspacing="1" cellpadding="2" width="100%" align="center"
					border="0">
					<tr class="bg_row_odd" height="20">
						<td class="top" colspan="6">
							<b>送货单信息</b>
						</td>
					</tr>
					<tr class="bg_row_odd" height="20">
						<td class="top" align="center" width="13%">
							<div align="center" class="txt_content">送货单号</div>
						</td>
						<td class="top" align="center" width="20%">
							<div align="left" class="txt_content">
							<INPUT type="text" name="devGoodsOrderId" maxlength="10"><font color=red>*</font>
							</div>
						</td>
						<td class="top" align="center" width="13%" >
							<div align="center" class="txt_content">签收人</div>
						</td>
						<td class="top" align="center" width="20%">
							<div align="left" class="txt_content">
								<input name='signer' type="text" maxlength="20"><font color=red>*</font>
							</div>
						</td>
						<td class="top" align="center" width="13%">
							<div align="center" class="txt_content">签收日期</div>
						</td>
						<td class="top" align="center" width="20%">
							<div align="left" class="txt_content">
								<input name='signDate' readonly onfocus='setday(this)'>
							</div>
						</td>
					</tr>
					<tr class="bg_row_odd" height="20">
						<td class="top" align="center" width="13%" >
							<div align="center" class="txt_content">价格</div>
						</td>
						<td class="top" align="center" width="20%">
							<div align="left" class="txt_content">
							<INPUT type="text" name="goodsUnitprice" maxlength="15" size=10 value="<%=tStr[9]%>">（元）<font color=red>*</font>
							</div>
						</td>
						<td class="top" align="center" width="13%" id='aaa'>
							<div align="center" class="txt_content">签收数量</div>
						</td>
						<td class="top" align="center" id='bbb' colspan="3">
							<div align="left" class="txt_content">
								<input name='signCount' type="text" maxlength="15"><font color=red>*</font>
							</div>
						</td>
					</tr>
					<tr class="bg_row_odd" height="20">
						<td class="top" align="center" width="13%" id='aaa'>
							<div align="center" class="txt_content">送货联系人</div>
						</td>
						<td class="top" align="center" width="20%">
							<div align="left" class="txt_content">
							<INPUT type="text" name="contactPerson" maxlength="20">
							</div>
						</td>
						<td class="top" align="center" width="13%">
							<div align="center" class="txt_content">联系电话</div>
						</td>
						<td class="top" align="center" colspan="3">
							<div align="left" class="txt_content">
								<input type="text" name="contactPhone" maxlength="50">
							</div>
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</table>
	</center>
</form>
    <p align="center">  
<!--		<input type="image" src="images/button/guanbi.gif" width="58" height="24" class="box" onclick="window.close();"/>&nbsp;		-->
		<input type="button" name="确定" value="确定" onClick="process('C')" class="kuang">
		<input type="button" name="取消" value="取消" onClick="window.close()" class="kuang">		
    </p>
 <%
}
 %>
</html>